Next | Prev | Up | Top | Contents | Index
Loop Unrolling Optimizations
The following options control loop unrolling in the MIPSpro 64-bit optimizer, that is, making multiple copies of a loop body to minimize the loop overhead or to expose more instruction parallelism. Unrolling is subject to a number of limits in the optimizer, intended to balance the runtime benefits against code expansion. These options allow the user to modify those limits when they can be improved. Note that loops expected to be software pipelined are subject to similar options in the -SWP group.
-OPT:unroll_times_max=n
The optimizer normally unrolls loops at most 2 times (-mips4) or 4 times (-mips3), unless it can unroll them completely. This option modifies the default limit.
-OPT:unroll_size=n
The optimizer normally unrolls loops only to the extent that the resulting unrolled loop body contains at most 320 instructions. This option modifies the default limit.
-OPT:unroll_bblimit=n
The optimizer normally unrolls loops containing up to 10 basic blocks. This option modifies the default limit. (A basic block is a sequence of code between branches and labels, that is, a sequece of code with a single entry at the top and a single exit at the bottom.)
Next | Prev | Up | Top | Contents | Index